home *** CD-ROM | disk | FTP | other *** search
/ Champak 45 / Vol 45.iso / games / cocoon.swf / scripts / frame_18 / PlaceObject2_288_147 / CLIPACTIONRECORD onClipEvent(enterFrame).as next >
Encoding:
Text File  |  2006-06-13  |  673 b   |  33 lines

  1. onClipEvent(enterFrame){
  2.    if(this.acceso == false)
  3.    {
  4.       _root.gamestopped = true;
  5.    }
  6.    else
  7.    {
  8.       _root.gamestopped = false;
  9.    }
  10.    if(this.acceso == true)
  11.    {
  12.       _root.timeleftformatted = Math.formatDecimals(_root.timeleft,1);
  13.       if(lasttime == undefined)
  14.       {
  15.          lasttime = getTimer();
  16.       }
  17.       if(getTimer() > lasttime + 100)
  18.       {
  19.          _root.timeleft -= 0.1;
  20.       }
  21.       else
  22.       {
  23.          addr64:
  24.          if(_root.timeleft <= 0)
  25.          {
  26.             _root.timeleftformatted = Math.formatDecimals(0,1);
  27.             _root.timeover = true;
  28.          }
  29.       }
  30.    }
  31.    ┬º┬ºgoto(addr64);
  32. }
  33.